import requests
import execjs
headers = {
    'Content-Type': 'text/xml;charset=UTF-8',
    'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36',
}
data = {
    "id": "rtom6v7dnc0m3nvr",
    "projectKey": "honsan_cloud_ccprec",
    "clientKey": "rtom4ztw4rknp6nj",
    "token": 'null',
    "clientDailyData": {},
    "acts": [
        {
            "id": "rtom6v7d1q8r1nmu",
            "fullPath": "/ccprec.com.cn.web/client/info/cqweb_nonphy_cqzr",
            "args": [
                4,
                20,
                'null'
            ]
        }
    ]
}
js_compile = execjs.compile(open('jlcccqjyzx.js',encoding='utf-8').read())
encrypt_data = js_compile.call('encryptData', 4,20)
print(encrypt_data)
response = requests.post('https://www.ccprec.com/honsanCloudAct', headers=headers, data=encrypt_data)
response_data = js_compile.call('decodeData', response.text)
print(response_data)
